<?php


namespace app\admin\service\config;

use app\admin\model\config\NewsConfig;
use app\admin\service\BaseService;

/**
 * 行为日志-服务类
 * @author tangsan
 * Class ActionLogService
 * @package app\admin\service
 */
class NewsConfigService extends BaseService
{
    /**
     * 构造函数
     * @author tangsan
     * ActionLogService constructor.
     */
    public function __construct()
    {
        $this->model = new NewsConfig();
    }

    /**
     * 获取数据列表
     * @return array
     * @author tangsan
     */
    public function getList()
    {
        $result = $this->model->select()->toArray();
        $data = [];
        if ($result) {
            $data = $result[0];
        }
        //返回结果
        $message = array(
            "msg" => '操作成功',
            "code" => 0,
            "data" => $data,
        );
        return $message;
    }

}